package com.punch.common.vo.order;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * OrderPageVO-订单列表
 *
 * @author wujj
 * @version 1.0.0
 * @since 2020/9/17 13:02
 */
@Data
public class OrderDetailVO implements Serializable {


    /**
     * 主订单id
     */
    @ApiModelProperty(name = "orderId", notes = "主订单id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long orderId;

    /**
     * 订单编号
     */
    @ApiModelProperty(name = "orderNo", notes = "订单编号")
    private String orderNo;


    @ApiModelProperty(name = "studentName", notes = "学生姓名")
    private String studentName;

    @ApiModelProperty(name = "studentClass", notes = "学校班级")
    private String studentClass;

    @ApiModelProperty(name = "schoolName", notes = "学生学校")
    private String schoolName;

    @ApiModelProperty(name = "orgName", notes = "机构名称")
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private String orgName;

    /**
     * 订单总金额
     */
    @ApiModelProperty(name = "totalPrice", notes = "订单总金额")
    private BigDecimal totalPrice;


    @ApiModelProperty(name = "createTime", notes = "订单创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    private Integer payChannel;

    @ApiModelProperty(name = "orderStatus", notes = "订单状态 0待付款 1待开班 2已开班 3已退款 4已取消")
    private Integer orderStatus;

    private String wxTransactionId;
}
